Retrieves the URL at the specified location.
obj.GetHTTPFile(URL String, [Data Variant], [BytesRead Long], [AccessType Long]) Where obj is an OpScrUtil.INet object.
URL
|
Specifies the URL to access. |
Data
|
Returns the text at the specified URL. This parameter is optional. |
BytesRead
|
Returns the number of bytes read from the specified URL. This parameter is optional. |
AccessType
|
Flags specify options for Internet connection. This parameter
is optional. Possible values for this parameter are as follows: INTERNET_OPEN_TYPE_PRECONFIG = 0 (default) Retrieves the proxy or direct configuration from the registry. INTERNET_OPEN_TYPE_DIRECT = 1 Resolves all host names locally. INTERNET_OPEN_TYPE_PROXY = 3 Passes requests to the proxy unless a proxy bypass list is supplied and the name to be resolved bypasses the proxy. In this case, the function uses INTERNET_OPEN_TYPE_DIRECT. INTERNET_OPEN_TYPE_PRECONFIG_WITH_NO_AUTOPROXY = 4 Retrieves the proxy or direct configuration from the registry and prevents the use of a startup JScript® (compatible with ECMA 262 language specification) or Internet Setup (INS) file. |
Boolean.
To retrieve the default.htm
web
page at http://www.missioncritical.com
, enter:
Set obj = CreateObject("OpScrUtil.INet") bOK = obj.GetHTTPFile("http://www.missioncritical.com/default.htm", varData, lngBytes) If Not bOK Then strError = obj.GetError() End If
This example retrieves the text at the specified URL.